<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html lang="en">
<head>

<title>添加试压员</title>
<meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible">
<meta name="viewport" content="width=device-width, initial-scale=1.0">

<link rel="stylesheet" href="../css/bootstrap.css" />
<link rel="stylesheet" href="../css/font-awesome.css" />

<link rel="stylesheet" href="../css/jquery-ui.css" />
<link rel="stylesheet" href="../css/datepicker.css" />

<link rel="stylesheet" href="../css/ace-fonts.css" />

<link rel="stylesheet" href="../css/ace.css" />
<!-- ie9 -->
<link rel="stylesheet" href="../css/ace-part2.css" />
<link rel="stylesheet" href="../css/ace-ie.css" />

<script src="../js/jquery.js"></script>
<script src='../js/ace/jquery.mobile.custom.js'></script>
<script src="../js/ace/bootstrap.js"></script>

<script src="../js/ace/ace/ace.js"></script>
<script src="../js/ace/ace/ace.sidebar.js"></script>
</head>
<body class=" no-skin">
	<jsp:include page="../../margin/head.jsp"></jsp:include>
	<div class="main-container" id="main-container">
		<jsp:include page="../../margin/left.jsp"></jsp:include>
		<div class="main-content">
			<!-- 导航菜单 -->
			<div class="breadcrumbs" id="breadcrumbs">
				<ul class="breadcrumb">
					<li><i class="ace-icon fa fa-home home-icon"></i> <a
						href="/LongShengManager/user/list">Home</a></li>
					<li><a href="/LongShengManager/user/list">试压员</a></li>
					<li class="active">添加试压员</li>
				</ul>
			</div>
			<div class="row">
				<div class="col-sm-12">
					<div class="widget-box">
						<div class="widget-header">
							<h4>添加用户</h4>
						</div>
						<div class="widget-body">
							<div class="widget-main no-padding">
								<form class="form-horizontal" action="/HuaJi/user/save"
									method="post" id="sysUserForm">
									<input type="hidden" name="userId" value="${u.userId}">
									<input type="hidden" id="accountOld" value="${u.account}">
									<div class="form-group">
										<label class="col-sm-3 control-label"><span style="color: red;">*</span> 姓名：</label>
										<div class="col-sm-4">
											<input class="form-control" id="s_userName" name="userName"
												required="required" value="${u.userName}" type="text"
												placeholder="请输入姓名" />
										</div>
									</div>
									<div class="form-group">
										<label class="col-sm-3 control-label"><span style="color: red;">*</span> 联系电话：</label>

										<div class="col-sm-4">
											<input class="form-control" id="phone" name="phone"
												type="text" value="${u.phone}" required="required"
												placeholder="请输入电话号码" />
										</div>
									</div>
									<div class="form-group">
										<label class="col-sm-3 control-label"><span style="color: red;">*</span> 用户账号：</label>

										<div class="col-sm-4">
											<input class="form-control" id="account" name="account"
												type="text" value="${u.account}" required="required"
												placeholder="请输入用户账号" /> <span style="color: red;"
												id="accountCheck"></span>
										</div>
									</div>
									<div class="form-group">
										<label class="col-sm-3 control-label"><span style="color: red;">*</span> 密码：</label>

										<div class="col-sm-4">
											<input class="form-control" id="repeat_pwd" name="password"
												type="text" value="${u.password}" required="required"
												placeholder="请输入密码" />
										</div>
									</div>
									<div class="form-group">
										<label class="col-sm-3 control-label">持卡人：</label>

										<div class="col-sm-4">
											<input class="form-control" id="cardUserName"
												name="cardUserName" type="text" value="${u.cardUserName}"
												placeholder="请输入持卡人" />
										</div>
									</div>

									<div class="form-group">
										<label class="col-sm-3 control-label">卡名：</label>

										<div class="col-sm-4">
											<input class="form-control" id="cardName" name="cardName"
												type="text" value="${u.cardName}"
												placeholder="请输入持卡人" />
										</div>
									</div>


									<div class="form-group">
										<label class="col-sm-3 control-label">卡号：</label>

										<div class="col-sm-4">
											<input class="form-control" id="cardNo" name="cardNo"
												type="text" value="${u.cardNo}"
												placeholder="请输入卡号" />
										</div>
									</div>
									<div class="form-actions center">
										<button type="button" class="btn btn-sm btn-grey"
											id="go_back_btn" onclick="returnList()">
											返回 <i class="icon-reply icon-on-right bigger-110"></i>
										</button>
										<button type="submit" onclick="check()"
											class="btn btn-sm btn-success" id="save_btn">
											保存 <i class="icon-save icon-on-right bigger-110"></i>
										</button>
									</div>
								</form>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>
	</div>
</body>
<script type="text/javascript">
	$(function() {
		$(".userMenta").addClass("active open");
		$(".userSta").addClass("active");
	});

	function check() {
		/* var account = $("#account").val();
		var accountOld = $("#accountOld").val();
		$.ajax({
			type : 'post',
			url : '/LongShengManager/user/check',
			dataType : "json",
			data : {
				accountOld : accountOld,
				account : account,
				type : 1
			},
			success : function(data) {
				if (data.data) { */
					$("#sysUserForm").submit();
				/* } else {
					$("#accountCheck").html("用户名重复");
				}
			}
		}); */
	}

	function returnList() {
		window.location = "${pageContext.request.contextPath}/user/list";
	}
</script>
</html>
